# @time     :2022/2/19
# @Author   :Simple
# @FileName :process
from multiprocessing import Pool


def open_process_pool(func, parm, num=1):
    """
    启用进程
    """
    with Pool(int(num)) as pool:
        pool.map(func, parm)
        pool.close()
        pool.join()
